<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <title>设置考试</title>
    <link href="{% static 'css/bootstrap.min.css' %}" rel="stylesheet">
    <link href="{% static 'css/sidebars.css' %}" rel="stylesheet">
    <link rel="stylesheet" href="{% static 'css/calendarTime.min.css' %}">
	<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
	<script src="{% static 'js/calendarTime.min.js' %}"></script>
    {{ form.media }}
    <style>
        html,body{
            background-color: rgba(0, 0, 0, .1);
            height: 100%;
        }
        main{
            width: 100%;
            height: 100%;
        }
    </style>
</head>
<body>
<main>
<div class="flex-shrink-0 p-3 bg-white" style="width: 200px;height:100%;border-right: 2px solid rgba(0,0,0,0.15);float: left">
    <a href="/" class="d-flex align-items-center pb-3 mb-3 link-dark text-decoration-none border-bottom">
      <span class="fs-5 fw-semibold">题型设置</span>
    </a>
    <ul class="list-unstyled ps-0">
      <li class="mb-1">
        <button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse" data-bs-target="#home-collapse" aria-expanded="true">
          单选题
        </button>
        <div class="collapse show" id="home-collapse">
          <ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small">
            <li><a href="{% url 'teacher:addque' %}?course={{ course }}&type=single" class="link-dark rounded">添加题目</a></li>
              {% for question in questions_single %}

                <li><a href="{% url 'teacher:updateque' %}?type=single&id={{ question.id }}&course={{ course }}" class="link-dark rounded">单选题{{ forloop.counter }}</a></li>

              {% endfor %}

          </ul>
        </div>
      </li>
      <li class="mb-1">
        <button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse" data-bs-target="#dashboard-collapse" aria-expanded="false">
          多选题
        </button>
        <div class="collapse" id="dashboard-collapse">
          <ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small">
            <li><a href="{% url 'teacher:addque' %}?course={{ course }}&type=multiple" class="link-dark rounded" >添加题目</a></li>
            {% for question in questions_multiple %}

                <li><a href="{% url 'teacher:updateque' %}?type=multiple&id={{ question.id }}&course={{ course }}" class="link-dark rounded">多选题{{ forloop.counter }}</a></li>

              {% endfor %}
          </ul>
        </div>
      </li>
      <li class="mb-1">
        <button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse" data-bs-target="#orders-collapse" aria-expanded="false">
          主观题
        </button>
        <div class="collapse" id="orders-collapse">
          <ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small">
            <li><a href="{% url 'teacher:addque' %}?course={{ course }}&type=subjective" class="link-dark rounded">添加题目</a></li>
            {% for question in questions_subjective %}

                <li><a href="{% url 'teacher:updateque' %}?type=subjective&id={{ question.id }}&course={{ course }}" class="link-dark rounded">主观题{{ forloop.counter }}</a></li>

              {% endfor %}
          </ul>
        </div>
      </li>
      <li class="border-top my-3"></li>
      <li class="mb-1">
        <button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse" data-bs-target="#account-collapse" aria-expanded="false">
            {{ front_user.name }}
        </button>
        <div class="collapse" id="account-collapse">
          <ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small">
            <li><a href="{% url 'teacher:release' %}?course={{ course }}" class="link-dark rounded">发布考试</a></li>
            <li><a href="{% url 'teacher:dashbord' %}" class="link-dark rounded">返回首页</a></li>
          </ul>
        </div>
      </li>
    </ul>

  </div>
<div style="width:1000px;height: 100px;margin-left: 50px;margin-top: 50px;float: right">
{% block que %}

{% endblock %}
</div>
</main>
<script src="{% static 'js/bootstrap.bundle.min.js' %}"></script>
<script src="{% static 'js/sidebars.js' %}"></script>
</body>
</html>